package com.yunlankeji.stemcells.fragemt.home;

import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;

import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.fragment.app.Fragment;
import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;

import com.yunlankeji.ganxibaozhijia.R;
import com.yunlankeji.stemcells.adapter.Fragment_organization_informationAdapter;
import com.yunlankeji.stemcells.adapter.Fragment_personal_space_followAdapter;
import com.yunlankeji.stemcells.model.request.Organization_information;

import java.util.ArrayList;
import java.util.List;

import butterknife.BindView;
import butterknife.ButterKnife;
import butterknife.Unbinder;

public class fragment_home_organization_information  extends Fragment {
    private Unbinder unbinder;
    @BindView(R.id.rv_organization_information)
    RecyclerView rv_organization_information;

    @Nullable
    @Override
    public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {

        View view=inflater.inflate(R.layout.fragment_home_organization_information,container,false);
        unbinder = ButterKnife.bind(this,view);


        List<Organization_information> organization_informationList = new ArrayList<>();

        Organization_information organization_information1 = new Organization_information("干细胞模型研究新冠肺炎多器官功能受损","华大基因",
                "2020.01.21 18:23:00","34","143",R.mipmap.icon_p2,R.mipmap.icon_p2);

        Organization_information organization_information2 = new Organization_information("干细胞模型研究新冠肺炎多器官功能受损","华大基因",
                "2020.01.21 18:23:00","34","143",R.mipmap.icon_p2,R.mipmap.icon_p2);

        Organization_information organization_information3 = new Organization_information("干细胞模型研究新冠肺炎多器官功能受损","华大基因",
                "2020.01.21 18:23:00","34","143",R.mipmap.icon_p2,R.mipmap.icon_p2);

        Organization_information organization_information4 = new Organization_information("干细胞模型研究新冠肺炎多器官功能受损","华大基因",
                "2020.01.21 18:23:00","34","143",R.mipmap.icon_p2,R.mipmap.icon_p2);

        Organization_information organization_information5 = new Organization_information("干细胞模型研究新冠肺炎多器官功能受损","华大基因",
                "2020.01.21 18:23:00","34","143",R.mipmap.icon_p2,R.mipmap.icon_p2);

        Organization_information organization_information6 = new Organization_information("干细胞模型研究新冠肺炎多器官功能受损","华大基因",
                "2020.01.21 18:23:00","34","143",R.mipmap.icon_p2,R.mipmap.icon_p2);

        Organization_information organization_information7 = new Organization_information("干细胞模型研究新冠肺炎多器官功能受损","华大基因",
                "2020.01.21 18:23:00","34","143",R.mipmap.icon_p2,R.mipmap.icon_p2);

        organization_informationList.add(organization_information1);
        organization_informationList.add(organization_information2);
        organization_informationList.add(organization_information3);
        organization_informationList.add(organization_information4);
        organization_informationList.add(organization_information5);
        organization_informationList.add(organization_information6);
        organization_informationList.add(organization_information7);


        LinearLayoutManager layoutManager = new LinearLayoutManager(this.getActivity());

        rv_organization_information.setLayoutManager(layoutManager);
        Fragment_organization_informationAdapter fragment_organization_informationAdapter=new Fragment_organization_informationAdapter(organization_informationList);
        rv_organization_information.setAdapter(fragment_organization_informationAdapter);

        return view;
    }
}
